

<form nz-form #validateForm="ngForm" (ngSubmit)="submitForm()" nzLayout="horizontal" autocomplete="off">
    <!-- 模态框头部 -->
    <div class="modal-header">
        <div class="modal-title">
            <i class="anticon anticon-medicine-box mr-sm"></i>
            <span *ngIf="entity.id">{{l('Edit')}}</span>
            <span *ngIf="!entity.id">{{l('Create')}}</span>
        </div>
    </div>
    <!-- 模态框内容 -->
    <fieldset>
        <!-- 提示信息 -->
        <!-- <nz-alert nzType="info" nzCloseable [nzShowIcon]="true" nzMessage="l('我想提示点什么内容给你说')"></nz-alert> -->
            <nz-form-item nz-row>
                    <nz-form-label nz-col [nzSm]="6" [nzXs]="24" nzRequired nzFor="deviceId">{{l('DeviceId')}}</nz-form-label>
                <nz-form-control nz-col [nzSm]="14" [nzXs]="24" nzHasFeedback>
                            <input nz-input name="deviceId" #deviceId="ngModel"
                                   [(ngModel)]="entity.deviceId"
                                   [placeholder]="l('DeviceId')"  required >

                            <!-- 校验 -->
                            <nz-form-explain *ngIf="deviceId.control.dirty&&deviceId.control.errors">
                                                                <ng-container *ngIf="deviceId.control.hasError('required')">{{l('CanNotNull')}}</ng-container>
                            </nz-form-explain>

                </nz-form-control>
            </nz-form-item>
            <nz-form-item nz-row>
                    <nz-form-label nz-col [nzSm]="6" [nzXs]="24" nzRequired nzFor="verifiableType">{{l('VerifiableType')}}</nz-form-label>
                <nz-form-control nz-col [nzSm]="14" [nzXs]="24" nzHasFeedback>
                            <input nz-input name="verifiableType" #verifiableType="ngModel"
                                   [(ngModel)]="entity.verifiableType"
                                   [placeholder]="l('VerifiableType')"  required >

                            <!-- 校验 -->
                            <nz-form-explain *ngIf="verifiableType.control.dirty&&verifiableType.control.errors">
                                                                <ng-container *ngIf="verifiableType.control.hasError('required')">{{l('CanNotNull')}}</ng-container>
                            </nz-form-explain>

                </nz-form-control>
            </nz-form-item>
            <nz-form-item nz-row>
                    <nz-form-label nz-col [nzSm]="6" [nzXs]="24" nzRequired nzFor="verifiableValue">{{l('VerifiableValue')}}</nz-form-label>
                <nz-form-control nz-col [nzSm]="14" [nzXs]="24" nzHasFeedback>
                            <input nz-input name="verifiableValue" #verifiableValue="ngModel"
                                   [(ngModel)]="entity.verifiableValue"
                                   [placeholder]="l('VerifiableValue')"  required >

                            <!-- 校验 -->
                            <nz-form-explain *ngIf="verifiableValue.control.dirty&&verifiableValue.control.errors">
                                                                <ng-container *ngIf="verifiableValue.control.hasError('required')">{{l('CanNotNull')}}</ng-container>
                            </nz-form-explain>

                </nz-form-control>
            </nz-form-item>
            <nz-form-item nz-row>
                    <nz-form-label nz-col [nzSm]="6" [nzXs]="24" nzRequired nzFor="returnState">{{l('ReturnState')}}</nz-form-label>
                <nz-form-control nz-col [nzSm]="14" [nzXs]="24" nzHasFeedback>
                            <input nz-input name="returnState" #returnState="ngModel"
                                   [(ngModel)]="entity.returnState"
                                   [placeholder]="l('ReturnState')"  required >

                            <!-- 校验 -->
                            <nz-form-explain *ngIf="returnState.control.dirty&&returnState.control.errors">
                                                                <ng-container *ngIf="returnState.control.hasError('required')">{{l('CanNotNull')}}</ng-container>
                            </nz-form-explain>

                </nz-form-control>
            </nz-form-item>
            <nz-form-item nz-row>
                    <nz-form-label nz-col [nzSm]="6" [nzXs]="24" nzRequired nzFor="returnInfo">{{l('ReturnInfo')}}</nz-form-label>
                <nz-form-control nz-col [nzSm]="14" [nzXs]="24" nzHasFeedback>
                            <input nz-input name="returnInfo" #returnInfo="ngModel"
                                   [(ngModel)]="entity.returnInfo"
                                   [placeholder]="l('ReturnInfo')"  required >

                            <!-- 校验 -->
                            <nz-form-explain *ngIf="returnInfo.control.dirty&&returnInfo.control.errors">
                                                                <ng-container *ngIf="returnInfo.control.hasError('required')">{{l('CanNotNull')}}</ng-container>
                            </nz-form-explain>

                </nz-form-control>
            </nz-form-item>

    </fieldset>
    <!-- 模态框底部 -->
    <div class="modal-footer">
        <button nz-button [nzType]="'default'" type="button" (click)="close()" [disabled]="saving">
            <i class="anticon anticon-close-circle-o"></i> {{l("Cancel")}}
        </button>
        <button nz-button [nzType]="'primary'" type="submit" [disabled]="!validateForm.form.valid|| saving" [nzLoading]="saving">
            <i class="anticon anticon-save" *ngIf="!saving"></i> {{l("Save")}}
        </button>
    </div>
</form>





